
let person = {
    profile: {
        name: "",
        age: 0
    }
}

console.log(person.profile.name || "Anonymous")           // Anonymous
console.log(person.profile.age || 18)                     // 18


console.log(person.profile.name ?? "Anonymous")           // 空
console.log(person.profile.age ?? 18)                     // 0

